from django.db import models

# Create your models here.


class User(models.Model):
    username=models.CharField(max_length=60)
    password=models.CharField(max_length=256)
    fen=models.IntegerField(default=0)

class Goods(models.Model):
    goods_name=models.CharField(max_length=60)
    goods_price=models.IntegerField(default=60)
    img=models.ImageField(upload_to="goods_img")

class Order(models.Model):
    user=models.ForeignKey(User,on_delete=models.CASCADE)
    goods=models.ForeignKey(Goods,on_delete=models.CASCADE)
    number = models.IntegerField(default=0)
